<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@include file="../../../commons/taglib.jsp" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>药品检测</title>
<link rel="stylesheet" href="${ctx}/static/css/pintuer.css">
    <link rel="stylesheet" href="${ctx}/static/css/admin.css">
    <script src="${ctx}/static/js/jquery.js"></script>
    <script src="${ctx}/static/js/pintuer.js"></script> 
</head>
<body>
<form method="post" action="excel">
	<div class="panel admin-panel">
		<div class="panel-head">
			<!-- <strong class="icon-reorder"> 挂号管理</strong> -->
			<select style="padding:5px 15px; border:1px solid #ddd;" onchange="change(this.value)">
            <option value="detection">药品有效期限检测</option>
            <option value="detection1" selected="selected">药品库存数量检测</option>
            <option value="detection2">药品审核单据检测</option>
          	</select>
			<div style="float: right;">
				<button class="button border-main excel" type="submit"> 导出Excel</button>
			    <a class="button border-main" href="detection1"> 刷新</a>
			</div>
			<div style="clear: both;"></div>
		</div>
		<div class="padding border-bottom">
			<ul class="search" style="padding-left:10px;">
				<li>
					<input type="text" class="input" placeholder="请输入药品名称" id="search"/>
				</li>
				<li>
					<a class="button border-main" href="JavaScript:;" onclick="location ='detection_search?name='+document.getElementById('search').value;"> 查询</a>
				</li>
				<li>
					<a href="detection1">清除搜索</a>
				</li>
			</ul>
		</div>
		<table class="table table-hover text-center">
		<tr>
			<th width="8%" style="text-align:left; padding:10px 0;padding-left:20px;border-bottom: 2px solid #ddd;border-top: 0px solid #ddd;font-weight: bold;"> ID </th>
			<th style="text-align: center;" width="14%">名称</th>
			<th style="text-align: center;">规格</th>
			<th style="text-align: center;">单位</th>
			<th style="text-align: center;">数量</th>
			<th style="text-align: center;">库存下限</th>
		</tr>
		<%-- <c:forEach items="${ drug }" var="list">
			<tr>
				<td style="text-align:left; padding-left:20px;border-bottom: 1px solid #ddd;"><input type="hidden" name="id" value="${list.id }" /> ${list.id }</td>
				<td style="border-bottom: 1px solid #ddd;"><input type="hidden" name="category" value="${list.name }"/>${list.name }</td>
				<td style="border-bottom: 1px solid #ddd;"><input type="hidden" name="name" value="${list.spec }"/>${list.spec }</td>
				<td style="border-bottom: 1px solid #ddd;"><input type="hidden" name="do_name" value="${list.tory }"/>${list.tory }</td>
				<td style="border-bottom: 1px solid #ddd;"><input type="hidden" name="sex" value="${list.p_price }"/>${list.p_price }</td>
				<td style="border-bottom: 1px solid #ddd;"><input type="hidden" name="fee" value="${list.price }"/>${list.price }</td>
				<td style="border-bottom: 1px solid #ddd;"><input type="hidden" name="deal" value="${list.yx_date }"/>${list.yx_date }</td>
			</tr>
		</c:forEach> --%>
		<c:if test="${ pageNumber!=null }">
			<tr>
				<td colspan="7">
					<div class="pagelist">
						<a href="detection?pageNumber=1">首页</a>
						<%-- <%if(){} %> --%>
						<c:if test="${ 1 != pageNumber && pageNumber >0 }">
							<a href="inventory?pageNumber=${pageNumber-1 }">上一页</a>
						</c:if>
						
						<c:if test="${ 0 != pageNumber-1 && 1 != pageNumber-1 && pageNumber >0 }">
							...
						</c:if>
						
						<c:if test="${ 1 != pageNumber && pageNumber >0 }">
							<a href="inventory?pageNumber=${pageNumber-1 }">${pageNumber-1 }</a>
						</c:if>
						
						<a href="inventory?pageNumber=${pageNumber }">${pageNumber }</a>
						
						<c:if test="${ Pages != pageNumber && pageNumber >0 }">
							<a href="inventory?pageNumber=${pageNumber+1 }">${pageNumber+1 }</a>
						</c:if>
						
						<c:if test="${ Pages != pageNumber && Pages != pageNumber+1 && pageNumber >0 }">
							...
						</c:if>
						
						<c:if test="${Pages != pageNumber && pageNumber >0 }">
							<a href="inventory?pageNumber=${pageNumber+1 }">下一页</a>
						</c:if>
						
						<a href="inventory?pageNumber=${Pages }">尾页</a>
						第${pageNumber }页/共${Pages }页
					</div>
				</td>
			</tr>
		</c:if>
		</table>
	</div>
</form>

</body>
<script type="text/javascript">
function change(data){
	window.location=data;
};
</script>
</html>